package com.mh.jdbc.enums;

public class LikeType {
	public static final int leftLink = 0;
	public static final int rightLike = 1;
	public static final int bathLike = 2;
	public static String Like(String s,int likeType){
		StringBuffer sb = new StringBuffer();
		switch (likeType) {
		case 0:
			sb.append(s).append('%');
			break;
		case 1:
			sb.append('%').append(s);
			break;
		case 2:
			sb.append('%').append(s).append('%');
			break;
		default:
			return "没有当前类型";
		}
		return sb.toString();
	}
}
